<?php
/**
 * Created by b17
 * 2/17/12 8:02 PM
 */

class Zend_View_Helper_Image extends Zend_View_Helper_Abstract
{
    public function image($url)
    {
        $dir = pathinfo($url, PATHINFO_DIRNAME);
        $name = pathinfo($url, PATHINFO_FILENAME);
        $ext = pathinfo($url, PATHINFO_EXTENSION);
        $smallName = mb_substr($name, 0, mb_strlen($name) - 1) . 's';
        $path = "{$dir}/{$smallName}.{$ext}";
        return $path;
    }
}
